import {createApp} from 'vue'
import App from './App.vue'

const app = createApp(App)

// Vue Router
import router from './router/index'

app.use(router)

// Pinia
import {createPinia} from 'pinia'

const pinia = createPinia()
app.use(pinia)

// ElementUI
import ElementPlus from 'element-plus'
import 'element-plus/dist/index.css'
import * as ElementPlusIconsVue from '@element-plus/icons-vue'

for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
    app.component(key, component)
}
app.use(ElementPlus)

// Vue beautiful chat
import Chat from 'vue3-beautiful-chat'

app.use(Chat)

// 挂载
app.mount('#app')
